﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace HA.ModFlow.Domain.DomainLayer
{

    /// <summary>
    /// 用于存储所有应力期的源汇实际数据
    /// </summary>
    [Serializable]
    public class SourceSink
    {

        public SourceSink(int nrows, int ncolumns, int nlayers, int nPeriods)
        {

            _specifiedHeads = new SpecifiedHeadCollecion(nrows,ncolumns,nlayers);

            _wells = new WellCollection(nrows, ncolumns, nlayers);

            _rivers = new RiverCollection(nrows, ncolumns, nlayers);

            _drains = new DrainCollection(nrows, ncolumns, nlayers);


            _generalHeads = new GHBCollection(nrows, ncolumns, nlayers);





            _evts = new EVTCollection(nrows, ncolumns, nlayers, nPeriods);

          
            _recharges = new RechargeCollection(nrows,ncolumns,nlayers,nPeriods);



            _uzfCollection = new UZFCollection(nrows, ncolumns, nlayers, nPeriods);

        
        }


        SpecifiedHeadCollecion _specifiedHeads;

        public SpecifiedHeadCollecion SpecifiedHeads
        {
            get { return _specifiedHeads; }
          
        }




        WellCollection _wells;


        /// <summary>
        /// 井数据集合
        /// </summary>
        public WellCollection Wells
        {
            get { return _wells; }
            
        }





        RiverCollection _rivers;

        public RiverCollection Rivers
        {
            get { return _rivers; }
            
        }



        DrainCollection _drains;

        public DrainCollection Drains
        {
            get { return _drains; }

        }


        GHBCollection _generalHeads;

        public GHBCollection GeneralHeads
        {
            get { return _generalHeads; }
            
        }




        EVTCollection _evts;

        public EVTCollection Evts
        {
            get { return _evts; }
           
        }


      


        RechargeCollection _recharges;

        public RechargeCollection Recharges
        {
            get { return _recharges; }


          
        }


        UZFCollection _uzfCollection;

        public UZFCollection UzfCollection
        {
            get { return _uzfCollection; }
            //set { _uzfCollection = value; }
        }



        public void OnGridReset(int nrows,int ncols,int nlayers)
        {


            this._drains.OnGridReset(nrows, ncols, nlayers);
            this._wells.OnGridReset(nrows,ncols,nlayers);
            this._rivers.OnGridReset(nrows, ncols, nlayers);

            this._generalHeads.OnGridReset(nrows, ncols, nlayers);
            this._specifiedHeads.OnGridReset(nrows, ncols, nlayers);





            this._recharges.OnGridReset(nrows, ncols, nlayers);

            this._uzfCollection.OnGridReset(nrows,ncols ,nlayers );

            this._evts.OnGridReset(nrows, ncols, nlayers);
           

            //this._drains.OnGridReset(nrows, ncols, nlayers);

 
        }
      

      

    }
}
